package com.maya.scoresUtility;

import android.content.Context;

public class ScoresManagerFactory 
{
	private static ScoresDbAdapter scoresDbAdapter = null;
	private static ScoresManager scoresManager = null;

	public static ScoresManager getScoresManager(Context context) 
	{
		if (scoresManager != null) 
		{
			return scoresManager;
		}

        scoresDbAdapter = new ScoresDbAdapter(context);
        scoresManager = new ScoresManager();
        scoresManager.setScoresDbAdapter(scoresDbAdapter);
        scoresManager.setHigherIsBetter(true);
        scoresManager.setHighScoresPerGame(12);

        return scoresManager;
	}
}
